//
//  DisCoverXuanShangPingLunViewController.m
//  随拍
//
//  Created by lanou3g on 16/1/19.
//  Copyright © 2016年 Ashoka. All rights reserved.
//

#import "DisCoverXuanShangPingLunViewController.h"

@interface DisCoverXuanShangPingLunViewController ()<UITextViewDelegate>

@property(nonatomic,strong)UITextView *aTextView;

@property(nonatomic,strong)UILabel * alabel;


@end

@implementation DisCoverXuanShangPingLunViewController



- (void)viewDidLoad {
    [super viewDidLoad];
   
  
    
    self.view.backgroundColor = [UIColor whiteColor];
    
    self.navigationItem.rightBarButtonItem = [[UIBarButtonItem alloc] initWithTitle:@"发送" style:UIBarButtonItemStylePlain target:self action:@selector(rightBarButton:)];
    
    self.title = @"评论";
    
    self.aTextView = [[UITextView alloc] initWithFrame:CGRectMake(0, 0, self.view.frame.size.width, 300)];
    
    
    _aTextView.backgroundColor = [UIColor cyanColor];
    
    self.alabel = [[UILabel alloc] initWithFrame:CGRectMake(5, 10, 120, 20)];
    
    _alabel.font = [UIFont systemFontOfSize:20];
    
    self.alabel.text = @"请输入评论:";
    
    _alabel.backgroundColor = [UIColor grayColor];
    
    //aTextField.placeholder = @"填写评论";
    
    _aTextView.delegate = self;
    
    [_aTextView addSubview:_alabel];
    
    [self.view addSubview:_aTextView];
    
    
    
}


- (void)textViewDidBeginEditing:(UITextView *)textView{

    [_alabel removeFromSuperview];



}


-(void)rightBarButton:(UIBarButtonItem *)sender{

    NSLog(@"发送评论");

}




- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    
    
}

/*
#pragma mark - Navigation

// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
    // Get the new view controller using [segue destinationViewController].
    // Pass the selected object to the new view controller.
}
*/

@end
